from django.db import models

# Create your models here.


class User(models.Model):
    id = models.AutoField(primary_key=True)
    username = models.CharField(max_length=32, unique=True)
    password = models.CharField(null=False, max_length=32)
    age = models.IntegerField(verbose_name='年龄')
    info = models.CharField(max_length=32, verbose_name='个人简介', null=True)
    hobby = models.CharField(max_length=32, verbose_name='爱好', default='study')

    def __str__(self):
        return self.username